<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>地图</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        #box {
            position: absolute;
            width: 100%;
            height: 100%;
            border: 1px solid red;
        }
    </style>
    <script src="./lib/echarts.min.js"></script>
    <script src="./lib/jquery.min.js"></script>
    <script>
        window.onload = () => {
            const myChart = echarts.init(document.querySelector('#box'))
            $.get('./map_data/province/guangdong.json', function (data) {
                echarts.registerMap('guangdong', data)
                myChart.setOption({
                    geo: {
                        map: 'guangdong',
                        label:{
                            show:true
                        },
                        zoom:1,
                        roam:true
                    }
                })
            })
        }
    </script>
</head>

<body>
    <div id="box"></div>
</body>

</html>